﻿package Common 
{
	
	/**
	 * @author fox
	 */
	public class GameDefine 
	{
		
//		public static const WEB:Boolean = false;
//		public static var PATH:String = "http://61.147.107.82/sa/";
//		public static var PATHUI:String = "http://61.147.107.82/sa/modules/ui/";
//		public static var PATH1:String = "";
		//public static var RES_SWF:String = PATH + "modules/ClientRes.swf";
		//public static var RESMAIN_SWF:String = PATH + "modules/ClientResMain.swf";
		
		
		
		public static const WEB:Boolean = true;
		public static var PATH:String = "";
		public static var PATHUI:String = "ui/";
		public static var PATH1:String = "../";
		public static var url:String = "";
		
		//public static var PATH1:String = "";
		
		public static var RESMAIN_SWF:String = "ClientResMain.swf";
		public static var LOGIN_SWF:String = "Login.swf";
		public static var MAIN_SWF:String = "Main.swf";
		
		public static const STR_ConnectDown:String = "網絡連接失敗，請重新登錄或刷新瀏覽器。";
		public static const STR_ConnectDown1:String = "網絡連接失敗，請檢查帳號或密碼是否輸入正確。";
		public static const STR_Connect:String = "連接服務器中，\n請稍後";
		//public static const STR_ConnectDown:String = "網絡連接失敗，請重新登錄或刷新瀏覽器";
		
		
		// server ip
		//public static const SERVER_HOST:String = "61.147.107.82";
		//public static const SERVER_HOST:String = "115.238.248.48";
		//public static const SERVER_HOST:String = "192.168.0.100";
		public static const SERVER_HOST:String = "127.0.0.1";
		
		// server port
		public static const SERVER_PORT:int = 5777;
		
		
		
		/********************************************/

		public static const SYSTEM_COLOR:String = "#eeee00";
		
		public static const BLOCK:int = 1;
		public static const SHADOW:int = 2;
		
		public static const INVALIDID:int = -1;
		
		// max name size
		public static const MAX_NAME:int = 32;
		
		// max chat size
		public static const MAX_CHAT:int = 128;
		
		// max chat size
		public static const MAX_CHAT_LINE:int = 32;
		
		// max move path
		public static const MAX_MOVE_PATH:int = 128;
		
		public static const MAX_NPC_TALK:int = 512;
		
		// max sys player
		public static const MAX_SYN_PLAYER:int = 128;	
		
		
		// default width
		public static const DEFAULT_WIDTH:int = 1024;
		
		// default height
		public static const DEFAULT_HEIGHT:int = 768;
		
		
		
		public static const MAX_ROOMS:int = 20;
		
		public static const MAX_TABLES:int = 50;
		
		public static const MAX_ROOM_PLAYERS:int = 4 * MAX_TABLES;
		
		public static const MAX_TABLE_PLAYERS:int = 4;
		
		public static function Init():void
		{
			//var xml:XML = CResManager.Instance().getSWF("res").getXML( "config" );
			
			//SERVER_HOST = xml.@ip;
			//SERVER_PORT = xml.@port;
			
			//xml = null;
		}
		
		public function GameDefine() 
		{
			
		}
		
	}
	
}